#ifndef VANGUARD_H
#define VANGUARD_H

#include <QMainWindow>
#include "Ability.h"
#include <string>
#include <vector>
using namespace std;

namespace Ui {
class Vanguard;
}

class Vanguard : public QMainWindow
{
    Q_OBJECT
    
public:
    explicit Vanguard(QWidget *parent = 0);
    ~Vanguard();
    void on_primaryBox_editingFinished();

    void on_powerBox_editingFinished();

    void on_critBox_editingFinished();

    void on_alacBox_editingFinished();

    void on_levelBox_editingFinished();

    void on_secondaryBox_editingFinished();

    void on_techBox_editingFinished();

    void on_surgeBox_editingFinished();

    void on_accBox_editingFinished();

    void on_MHmaxBox_editingFinished();

    void on_MHminBox_editingFinished();

    void on_enemyLevelBox_editingFinished();

    void on_enemyArmorBox_editingFinished();

    void on_calcDPSButton_clicked();

    void on_calcWeightButton_clicked();

    void on_upgradeButton_clicked();

    void on_check4pcBox_toggled(bool checked);

    void on_check2pcBox_toggled(bool checked);

    void on_computeAlacrityButton_clicked();

    void on_skillBox_1_editingFinished();

    void on_skillBox_2_editingFinished();

    void on_skillBox_3_editingFinished();

    void on_skillBox_4_editingFinished();

    void on_skillBox_5_editingFinished();

    void on_skillBox_6_editingFinished();

    void on_skillBox_7_editingFinished();

    void on_skillBox_8_editingFinished();

    void on_skillBox_9_editingFinished();

    void on_note1_clicked();

    void on_note2_clicked();

    void on_saveStats_clicked();

    void on_loadStats_clicked();
    
private slots:
    void on_tree1_clicked();

    void on_tree2_clicked();

    void on_tree3_clicked();

private:
    Ui::Vanguard *ui;
    void setStats();
    vector <double> calculateStats(vector <double> &stats2);
    void updateStatBoxes();
    void updateCooldowns(double tTime, string ability);
    double getMitigation(int d_armor, int d_def, int d_shield, int d_absorb);
    double calculateDPS();
    void getWeights();
    void compareUpgrades();
    void computeAlacrity();
    double tacticsRotation();
    double assaultRotation();
    void Load_Stats();
};

#endif // VANGUARD_H
